package com.caesar.Date.third;

import org.junit.jupiter.api.Test;

import java.time.Instant;
import java.time.ZonedDateTime;

/**
 * @author caesar
 * @date 2025/7/15
 * @Description:测试Instant，本初子午线的时间
 * @apiNote
 */
public class TestInstant {
    @Test
    public void test1(){
        Instant now = Instant.now();//本初子午线的时间
        System.out.println(now );
        //2025-07-15T01:38:49.992202700Z
    }

    @Test
    public void test2(){
        ZonedDateTime zdt = ZonedDateTime.now();
        System.out.println(zdt);
        //2025-07-15T09:36:32.291563700+08:00[Asia/Shanghai]
    }
}
